home *** CD-ROM | disk | FTP | other *** search
/ GameStar 2004 April / Gamestar_61_2004-04_dvdb.iso / DVDStar / Editace / hltp.exe / {app} / Source Code / Half-Life Model Viewer / src / ControlPanel.h < prev    next >
C/C++ Source or Header  |  1999-10-20  |  3KB  |  148 lines

  1. //
  2. //                 Half-Life Model Viewer (c) 1999 by Mete Ciragan
  3. //
  4. // file:           ControlPanel.h
  5. // last modified:  Oct 20 programs and associated files contained in this
  6. //                 distribution were developed by Mete Ciragan. The programs
  7. //                 are not in the public domain, but they are freely
  8. //                 distributable without licensing fees. These programs are
  9. //                 provided without guarantee or warrantee expressed or
  10. //                 implied.
  11. //
  12. // version:        1.24
  13. //
  14. // email:          mete@swissquake.ch
  15. // web:            http://www.swissquake.ch/chumbalum-soft/
  16. //
  17. #ifndef INCLUDED_CONTROLPANEL
  18. #define INCLUDED_CONTROLPANEL
  19.  
  20.  
  21.  
  22. #ifndef INCLUDED_MXWINDOW
  23. #include <mx/mxWindow.h>
  24. #endif
  25.  
  26.  
  27. #define IDC_TAB                        1901
  28. #define IDC_RENDERMODE                2001
  29. #define IDC_TRANSPARENCY            2002
  30. #define IDC_GROUND                    2003
  31. #define IDC_MIRROR                    2004
  32. #define IDC_BACKGROUND                2005
  33. #define IDC_HITBOXES                2006
  34. #define IDC_BONES                    2007
  35. #define IDC_ATTACHMENTS                2008
  36.  
  37. #define IDC_SEQUENCE                3001
  38. #define IDC_SPEEDSCALE                3002
  39. #define IDC_STOP                    3003
  40. #define IDC_PREVFRAME                3004
  41. #define IDC_FRAME                    3005
  42. #define IDC_NEXTFRAME                3006
  43.  
  44. #define IDC_BODYPART                4001
  45. #define IDC_SUBMODEL                4002
  46. #define IDC_CONTROLLER                4003
  47. #define IDC_CONTROLLERVALUE            4004
  48. #define IDC_SKINS                    4005
  49.  
  50. #define IDC_TEXTURES                5001
  51. #define IDC_EXPORTTEXTURE            5002
  52. #define IDC_IMPORTTEXTURE            5003
  53. #define IDC_SAVEMODEL                5004
  54. #define IDC_TEXTURESCALE            5005
  55. #define IDC_CHROME                    5006
  56.  
  57. #define IDC_FULLSCREEN                6001
  58.  
  59.  
  60.  
  61. class mxTab;
  62. class mxChoice;
  63. class mxCheckBox;
  64. class mxSlider;
  65. class mxLineEdit;
  66. class mxLabel;
  67. class mxButton;
  68. class mxToggleButton;
  69. class GlWindow;
  70. class TextureWindow;
  71.  
  72.  
  73.  
  74. class ControlPanel : public mxWindow
  75. {
  76.     mxTab *tab;
  77.     mxChoice *cRenderMode;
  78.     mxSlider *slTransparency;
  79.     mxCheckBox *cbGround, *cbMirror, *cbBackground;
  80.     mxChoice *cSequence;
  81.     mxSlider *slSpeedScale;
  82.     mxToggleButton *tbStop;
  83.     mxButton *bPrevFrame, *bNextFrame;
  84.     mxLineEdit *leFrame;
  85.     mxChoice *cBodypart, *cController, *cSubmodel;
  86.     mxSlider *slController;
  87.     mxChoice *cSkin;
  88.     mxLabel *lModelInfo1, *lModelInfo2;
  89.     mxChoice *cTextures;
  90.     mxCheckBox *cbChrome;
  91.     mxLabel *lTexSize;
  92.     mxLineEdit *leWidth, *leHeight;
  93.     mxCheckBox *cb3dfxOpenGL;
  94.  
  95.     mxLineEdit *leMeshScale, *leBoneScale;
  96.  
  97.     GlWindow *d_GlWindow;
  98.     TextureWindow *d_textureWindow;
  99.  
  100. public:
  101.     // CREATORS
  102.     ControlPanel (mxWindow *parent);
  103.     virtual ~ControlPanel ();
  104.  
  105.     // MANIPULATORS
  106.     int handleEvent (mxEvent *event);
  107.  
  108.     void dumpModelInfo ();
  109.     void loadModel (const char *filename);
  110.  
  111.     void setRenderMode (int mode);
  112.     void setShowGround (bool b);
  113.     void setMirror (bool b);
  114.     void setShowBackground (bool b);
  115.  
  116.     void initSequences ();
  117.     void setSequence (int index);
  118.  
  119.     void initBodyparts ();
  120.     void setBodypart (int index);
  121.     void setSubmodel (int index);
  122.  
  123.     void initBoneControllers ();
  124.     void setBoneController (int index);
  125.     void setBoneControllerValue (int index, float value);
  126.  
  127.     void initSkins ();
  128.  
  129.     void setModelInfo ();
  130.  
  131.     void initTextures ();
  132.  
  133.     void centerView ();
  134.  
  135.     void fullscreen ();
  136.  
  137.     void setGlWindow (GlWindow *window) { d_GlWindow = window; }
  138.  
  139.     // no ACCESSORS
  140. };
  141.  
  142.  
  143.  
  144. extern ControlPanel *g_ControlPanel;
  145.  
  146.  
  147.  
  148. #endif // INCLUDED_CONTROLPANEL